package model;

import java.util.Vector;

public class Manager{
	private static Manager theManager;
	
	public static Manager getTheManager(){
		if(theManager == null) theManager = new Manager();
		return theManager;
	}

	private Vector<PartCall> allPartCalls;
	
	private Manager(){
		this.setAllPartCalls(new Vector<PartCall>());
	}
		
	public Vector<PartCall> getAllPartCalls() {
		return allPartCalls;
	}

	public void setAllPartCalls(Vector<PartCall> allPartCalls) {
		this.allPartCalls = allPartCalls;
	}	
		
	public PartCall startNewPartCall(QuantifiedComponent quantifiedComponent){
		PartCall newPartCall = PartCall.create(quantifiedComponent);
		this.getAllPartCalls().add(newPartCall);
		newPartCall.start();
		return newPartCall;
	}	
		
		
		
		
	
}
